<%
var currentSection = $0;
var locale = env.locale;

function state(section) {
  if (section == currentSection) {
    return "open";
  }
  return "";
}

var text = mdn.localStringMap({
  'en-US': {
    'Service_Worker_API': 'Service Worker API',
    'Overview': 'Overview of Service Worker interfaces',
    'Service_Worker_guides': 'Service Worker guides',
    'Interfaces': 'Interfaces',
    'Documentation': 'Documentation:',
    'Useful_lists': 'Useful lists',
    'Contribute': 'Contribute',
    'The_MDN_project': 'The MDN project',
    'Using_Service_Workers': 'Using Service Workers',
    'Related_APIs': 'Related APIs',
    'Push_API': 'Push API',
    'Notifications_API': 'Notifications API',
    'Channel_Messaging_API': 'Channel Messaging API',
    'Web_Workers_API': 'Web Workers API'
  },
  'ru': {
    'Service_Worker_API': 'Service Worker API',
    'Overview': 'Обзор интерфейсов Service Worker',
    'Service_Worker_guides': 'Руководства по Service Worker',
    'Interfaces': 'Интерфейсы',
    'Documentation': 'Документация:',
    'Useful_lists': 'Полезные списки',
    'Contribute': 'Внести вклад',
    'The_MDN_project': 'Проект MDN',
    'Using_Service_Workers': 'Использование Service Workers',
    'Related_APIs': 'Похожие API',
    'Push_API': 'Push API',
    'Notifications_API': 'Notifications API',
    'Channel_Messaging_API': 'Channel Messaging API',
    'Web_Workers_API': 'Web Workers API'
  }
});
%>
<section id="Quick_links">
 <ol>
  <li><a href="/<%=locale%>/docs/Web/API/Service_Worker_API"><strong><%=text['Service_Worker_API']%></strong></a></li>
  <li class="toggle">
    <details open>
        <summary><%=text['Service_Worker_guides']%></summary>
        <ol>
          <li><a href="/<%=locale%>/docs/Web/API/Service_Worker_API/Using_Service_Workers"><%=text['Using_Service_Workers']%></a></li>
        </ol>
    </details>
  </li>
  <li class="toggle">
    <details open>
        <summary><%=text['Interfaces']%></summary>
        <ol>
          <li><%-await template("domxref", ["Cache"])%></li>
          <li><%-await template("domxref", ["CacheStorage"])%></li>
          <li><%-await template("domxref", ["Client"])%></li>
          <li><%-await template("domxref", ["Clients"])%></li>
          <li><%-await template("domxref", ["ExtendableEvent"])%></li>
          <li><%-await template("domxref", ["FetchEvent"])%></li>
          <li><%-await template("domxref", ["InstallEvent"])%></li>
          <li><%-await template("domxref", ["Navigator.serviceWorker"])%></li>
          <li><%-await template("domxref", ["NotificationEvent"])%></li>
          <li><%-await template("domxref", ["PeriodicSyncEvent"])%></li>
          <li><%-await template("domxref", ["PeriodicSyncManager"])%></li>
          <li><%-await template("domxref", ["PeriodicSyncRegistration"])%></li>
          <li><%-await template("domxref", ["ServiceWorker"])%></li>
          <li><%-await template("domxref", ["ServiceWorkerContainer"])%></li>
          <li><%-await template("domxref", ["ServiceWorkerGlobalScope"])%></li>
          <li><%-await template("domxref", ["ServiceWorkerRegistration"])%></li>
          <li><%-await template("domxref", ["SyncEvent"])%></li>
          <li><%-await template("domxref", ["SyncManager"])%></li>
          <li><%-await template("domxref", ["SyncRegistration"])%></li>
          <li><%-await template("domxref", ["WindowClient"])%></li>
        </ol>
    </details>
  </li>
  <li class="toggle">
    <details open>
        <summary><%=text['Related_APIs']%></summary>
        <ol>
          <li><a href="/<%=locale%>/docs/Web/API/Channel_Messaging_API"><%=text['Channel_Messaging_API']%></a></li>
          <li><a href="/<%=locale%>/docs/Web/API/Notifications_API"><%=text['Notifications_API']%></a></li>
          <li><a href="/<%=locale%>/docs/Web/API/Push_API"><%=text['Push_API']%></a></li>
          <li><a href="/<%=locale%>/docs/Web/API/Web_Workers_API"><%=text['Web_Workers_API']%></a></li>
        </ol>
    </details>
  </li>
  <li><strong><a href="/<%=locale%>/docs/MDN"><%=text['Documentation']%></a></strong></li>
  <li class="toggle">
    <details <%=state('Contribute')%>>
        <summary><%=text['Contribute']%></summary>
        <ol>
          <li><a href="/<%=locale%>/docs/MDN"><%=text['The_MDN_project']%></a></li>
        </ol>
    </details>
  </li>
 </ol>
</section>
